/**********************************
 * 文件:qt 下gsoap hmi用
 * 创建者:华磊
 * 创建时间:2020.11.4
 * copyright:(c)深圳市华友高科有限公司
 * 备注:有未确定数据类型,暂时"待定"
 *
 * 修改者:华磊  2020.11.30 更新异常判断 断线判断 更新函数与hmi对接
 **********************************/

#include "hmicommunicate.h"


HmiCommunicate::HmiCommunicate()
{
    globalData = NULL;

    qDebug()<<"init client_soap";
    soap_init(&client_soap);
    client_soap.connect_timeout = 2;
    client_soap.send_timeout = 1;//超时判定
    client_soap.recv_timeout = 1;
    soap_set_mode(&client_soap,SOAP_C_UTFSTRING);//UTF-8
}

HmiCommunicate::~HmiCommunicate()
{
    if(globalData)
    {
//        globalData->lock();
        qDebug()<<"globalData lv:"<<globalData->ioUpdateFlag <<" stop";
        globalData->ioUpdateFlag = E_UPDATA_TYPE_NONE;
//        globalData->unlock();

//        delete globalData;
//        globalData = NULL;
    }
}
